
<form class="login-form  Absolute-Center mt11" (ngSubmit)="onRegister()" #loginForm = "ngForm">
  {{diagnostic}}
  <div class="form-group">
    <label>用户名</label>
    <mat-form-field class="login-full-width">
      <input matInput
             required
             [(ngModel)]="user.name" name="name"
      >
    </mat-form-field>
  </div>

  <div class="form-group">
    <label>密码</label>
    <mat-form-field class="login-full-width">
      <input #pwd matInput
             required
             [(ngModel)]="user.password" name="name"
      >
    </mat-form-field>
  </div>

  <div class="form-group">
    <label>邮箱</label>
    <mat-form-field class="login-full-width">
      <input #email matInput
             required
             [(ngModel)]="user.email" name="email"
      >
    </mat-form-field>
  </div>


  <button mat-button color="primary" type="submit" >注册</button>
  <button mat-button color="primary" (click)="goLogin()" >登录</button>
</form>






